package com.jmar.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.jmar.bean.User;
import com.jmar.dao.UserDao;
import com.jmar.service.UserServiceI;

@Service
public class UserServiceImpl implements UserServiceI {

	@Autowired
	private UserDao userDao;

	@Override
	public int insertUser(User user) {
		int insertUser = userDao.insertUser(user);
		return insertUser;
	}

	@Override
	public User info(int id) {
		return userDao.info(id);
	}

	@Override
	public void del(int id) {
		userDao.del(id);
	}

	@Override
	public List<User> all() {
		return userDao.all();
	}

	@Override
	public void update(User user) {
		userDao.update(user);
	}

}
